﻿namespace BarrageGameAssistant.Core.Enums
{
    /// <summary>
    /// 过程识别匹配类型
    /// </summary>
    public enum ProcessMatchType
    {
        /// <summary>
        /// 图形标定
        /// </summary>
        None = 0,
        /// <summary>
        /// 全字符匹配
        /// </summary>
        AllOcr = 1,
        /// <summary>
        /// 数字识别
        /// </summary>
        Numeric = 2,

        /// <summary>
        /// 中文识别
        /// </summary>
        Chinese = 3,

        /// <summary>
        /// 英文识别
        /// </summary>
        English = 4,

        /// <summary>
        /// 横进度条识别
        /// </summary>
        HorizontalProgressBar = 5,

        /// <summary>
        /// 竖进度条识别
        /// </summary>
        VerticalProgressBar = 6,

        /// <summary>
        /// 位置追踪(结果输出box)
        /// </summary>
        Tracker = 7
    }

    public static class ProcessMatchTypeExtension
    {
        public static string ToDesc(this ProcessMatchType processMatchType)
        {
            if (processMatchType == ProcessMatchType.AllOcr)
                return "全字符匹配";
            else if (processMatchType == ProcessMatchType.Numeric)
                return "数字识别";
            else if (processMatchType == ProcessMatchType.Chinese)
                return "中文识别";
            else if (processMatchType == ProcessMatchType.English)
                return "英文识别";
            else if (processMatchType == ProcessMatchType.HorizontalProgressBar)
                return "横进度条识别";
            else if (processMatchType == ProcessMatchType.VerticalProgressBar)
                return "竖进度条识别";
            else if (processMatchType == ProcessMatchType.Tracker)
                return "位置追踪";
            else
                return "图形标定";
        }
    }
}
